<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  <html xmlns="http://www.w3.org/1999/xhtml">
		<head>
			<!-- template designed by Marco Von Ballmoos -->
			<title>Docs For Class Swift_Connection_SMTP</title>
			<link rel="stylesheet" href="../media/stylesheet.css" />
			<meta http-equiv='Content-Type' content='text/html; charset=iso-8859-1'/>
		</head>
		<body>
			<div class="page-body">			
<h2 class="class-name">Class Swift_Connection_SMTP</h2>

<a name="sec-description"></a>
<div class="info-box">
	<div class="info-box-title">Description</div>
	<div class="nav-bar">
					<span class="disabled">Description</span> |
													<a href="#sec-var-summary">Vars</a> (<a href="#sec-vars">details</a>)
						|											<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
						
					</div>
	<div class="info-box-body">
        		<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Swift SMTP Connection</p>
	<ul class="tags">
				<li><span class="field">author:</span> Chris Corbyn &lt;<a href="mailto:chris@w3style.co.uk">chris@w3style.co.uk</a>&gt;</li>
			</ul>
		<p class="notes">
			Located in <a class="field" href="_Swift---Connection---SMTP.php.html">/Swift/Connection/SMTP.php</a> (line <span class="field">26</span>)
		</p>
		
				
		<pre><a href="../Swift_Connection/Swift_Connection.html">Swift_Connection</a>
   |
   --<a href="../Swift_Connection/Swift_ConnectionBase.html">Swift_ConnectionBase</a>
      |
      --Swift_Connection_SMTP</pre>
	
			</div>
</div>



	<a name="sec-var-summary"></a>
	<div class="info-box">
		<div class="info-box-title">Variable Summary</span></div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
						<span class="disabled">Vars</span> (<a href="#sec-vars">details</a>)
							| 
									<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
							
								</div>
		<div class="info-box-body">
			<div class="var-summary">
																																																																																																																																								<div class="var-title">
					<span class="var-type">array</span>
					<a href="#$authenticators" title="details" class="var-name">$authenticators</a>
				</div>
																<div class="var-title">
					<span class="var-type">mixed</span>
					<a href="#$AUTO_DETECT" title="details" class="var-name">$AUTO_DETECT</a>
				</div>
																<div class="var-title">
					<span class="var-type">int</span>
					<a href="#$encryption" title="details" class="var-name">$encryption</a>
				</div>
																<div class="var-title">
					<span class="var-type">mixed</span>
					<a href="#$ENC_OFF" title="details" class="var-name">$ENC_OFF</a>
				</div>
																<div class="var-title">
					<span class="var-type">mixed</span>
					<a href="#$ENC_SSL" title="details" class="var-name">$ENC_SSL</a>
				</div>
																<div class="var-title">
					<span class="var-type">mixed</span>
					<a href="#$ENC_TLS" title="details" class="var-name">$ENC_TLS</a>
				</div>
																<div class="var-title">
					<span class="var-type">int</span>
					<a href="#$errno" title="details" class="var-name">$errno</a>
				</div>
																<div class="var-title">
					<span class="var-type">string</span>
					<a href="#$errstr" title="details" class="var-name">$errstr</a>
				</div>
																<div class="var-title">
					<span class="var-type">resource</span>
					<a href="#$handle" title="details" class="var-name">$handle</a>
				</div>
																<div class="var-title">
					<span class="var-type">string</span>
					<a href="#$password" title="details" class="var-name">$password</a>
				</div>
																<div class="var-title">
					<span class="var-type">int</span>
					<a href="#$port" title="details" class="var-name">$port</a>
				</div>
																<div class="var-title">
					<span class="var-type">mixed</span>
					<a href="#$PORT_DEFAULT" title="details" class="var-name">$PORT_DEFAULT</a>
				</div>
																<div class="var-title">
					<span class="var-type">mixed</span>
					<a href="#$PORT_SECURE" title="details" class="var-name">$PORT_SECURE</a>
				</div>
																<div class="var-title">
					<span class="var-type">int</span>
					<a href="#$timeout" title="details" class="var-name">$timeout</a>
				</div>
																<div class="var-title">
					<span class="var-type">string</span>
					<a href="#$username" title="details" class="var-name">$username</a>
				</div>
											</div>
		</div>
	</div>

	<a name="sec-method-summary"></a>
	<div class="info-box">
		<div class="info-box-title">Method Summary</span></div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
																		<a href="#sec-var-summary">Vars</a> (<a href="#sec-vars">details</a>)
				 
				|
						<span class="disabled">Methods</span> (<a href="#sec-methods">details</a>)
		</div>
		<div class="info-box-body">			
			<div class="method-summary">
																																																																																																																																																																																												
												<div class="method-definition">
											<span class="method-result">Swift_Connection_SMTP</span>
										<a href="#Swift_Connection_SMTP" title="details" class="method-name">Swift_Connection_SMTP</a>
											([<span class="var-type">string</span>&nbsp;<span class="var-name">$server</span> = <span class="var-default">&quot;localhost&quot;</span>], [<span class="var-type">int</span>&nbsp;<span class="var-name">$port</span> = <span class="var-default">null</span>], [<span class="var-type">int</span>&nbsp;<span class="var-name">$encryption</span> = <span class="var-default">null</span>])
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#__destruct" title="details" class="method-name">__destruct</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#attachAuthenticator" title="details" class="method-name">attachAuthenticator</a>
											(<span class="var-type"><a href="../Swift_Authenticator/Swift_Authenticator.html">Swift_Authenticator</a></span>&nbsp;<span class="var-name">&$auth</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">int</span>
										<a href="#getEncryption" title="details" class="method-name">getEncryption</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">string</span>
										<a href="#getPassword" title="details" class="method-name">getPassword</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">int</span>
										<a href="#getPort" title="details" class="method-name">getPort</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">string</span>
										<a href="#getServer" title="details" class="method-name">getServer</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">int</span>
										<a href="#getTimeout" title="details" class="method-name">getTimeout</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">string</span>
										<a href="#getUsername" title="details" class="method-name">getUsername</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">boolean</span>
										<a href="#isAlive" title="details" class="method-name">isAlive</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#postConnect" title="details" class="method-name">postConnect</a>
											(<span class="var-type"><a href="../Swift/Swift.html">Swift</a></span>&nbsp;<span class="var-name">&$instance</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">string</span>
										<a href="#read" title="details" class="method-name">read</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#runAuthenticators" title="details" class="method-name">runAuthenticators</a>
											(<span class="var-type">string</span>&nbsp;<span class="var-name">$user</span>, <span class="var-type">string</span>&nbsp;<span class="var-name">$pass</span>, <span class="var-type"><a href="../Swift/Swift.html">Swift</a></span>&nbsp;<span class="var-name">&$swift</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#setEncryption" title="details" class="method-name">setEncryption</a>
											(<span class="var-type">int</span>&nbsp;<span class="var-name">$enc</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#setPassword" title="details" class="method-name">setPassword</a>
											(<span class="var-type">string</span>&nbsp;<span class="var-name">$pass</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#setPort" title="details" class="method-name">setPort</a>
											(<span class="var-type">int</span>&nbsp;<span class="var-name">$port</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#setServer" title="details" class="method-name">setServer</a>
											(<span class="var-type">string</span>&nbsp;<span class="var-name">$server</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#setTimeout" title="details" class="method-name">setTimeout</a>
											(<span class="var-type">int</span>&nbsp;<span class="var-name">$time</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#setUsername" title="details" class="method-name">setUsername</a>
											(<span class="var-type">string</span>&nbsp;<span class="var-name">$user</span>)
									</div>
																<div class="method-definition">
											<span class="method-result">string</span>
										<a href="#smtpErrors" title="details" class="method-name">smtpErrors</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#start" title="details" class="method-name">start</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#stop" title="details" class="method-name">stop</a>
										()
									</div>
																<div class="method-definition">
											<span class="method-result">void</span>
										<a href="#write" title="details" class="method-name">write</a>
											(<span class="var-type">string</span>&nbsp;<span class="var-name">$command</span>, [<span class="var-type"></span>&nbsp;<span class="var-name">$end</span> = <span class="var-default">&quot;\r\n&quot;</span>])
									</div>
								</div>
		</div>
	</div>		

	<a name="sec-vars"></a>
	<div class="info-box">
		<div class="info-box-title">Variables</div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
										<a href="#sec-var-summary">Vars</a> (<span class="disabled">details</span>)
						
			
										| 
									<a href="#sec-method-summary">Methods</a> (<a href="#sec-methods">details</a>)
							
					</div>
		<div class="info-box-body">
			<a name="var$authenticators" id="$authenticators"><!-- --></A>
<div class="evenrow">

	<div class="var-header">
		<span class="var-title">
			<span class="var-type">array</span>
			<span class="var-name">$authenticators</span>
			 = <span class="var-default">array()</span>			(line <span class="line-number">86</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Loaded authentication mechanisms</p>
	
	
		
		

</div>
<a name="var$AUTO_DETECT" id="$AUTO_DETECT"><!-- --></A>
<div class="oddrow">

	<div class="var-header">
		<span class="var-title">
			<span class="var-type">mixed</span>
			<span class="var-name">$AUTO_DETECT</span>
			 = <span class="var-default"> SWIFT_SMTP_AUTO_DETECT</span>			(line <span class="line-number">51</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Constant for auto-detection of paramters</p>
	
	
		
		

</div>
<a name="var$encryption" id="$encryption"><!-- --></A>
<div class="evenrow">

	<div class="var-header">
		<span class="var-title">
			<span class="var-type">int</span>
			<span class="var-name">$encryption</span>
			 = <span class="var-default"> null</span>			(line <span class="line-number">66</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Encryption type to use</p>
	
	
		
		

</div>
<a name="var$ENC_OFF" id="$ENC_OFF"><!-- --></A>
<div class="oddrow">

	<div class="var-header">
		<span class="var-title">
			<span class="var-type">mixed</span>
			<span class="var-name">$ENC_OFF</span>
			 = <span class="var-default"> SWIFT_SMTP_ENC_OFF</span>			(line <span class="line-number">39</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Constant for unencrypted connections</p>
	
	
		
		

</div>
<a name="var$ENC_SSL" id="$ENC_SSL"><!-- --></A>
<div class="evenrow">

	<div class="var-header">
		<span class="var-title">
			<span class="var-type">mixed</span>
			<span class="var-name">$ENC_SSL</span>
			 = <span class="var-default"> SWIFT_SMTP_ENC_SSL</span>			(line <span class="line-number">35</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Constant for SSL connections</p>
	
	
		
		

</div>
<a name="var$ENC_TLS" id="$ENC_TLS"><!-- --></A>
<div class="oddrow">

	<div class="var-header">
		<span class="var-title">
			<span class="var-type">mixed</span>
			<span class="var-name">$ENC_TLS</span>
			 = <span class="var-default"> SWIFT_SMTP_ENC_TLS</span>			(line <span class="line-number">31</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Constant for TLS connections</p>
	
	
		
		

</div>
<a name="var$errno" id="$errno"><!-- --></A>
<div class="evenrow">

	<div class="var-header">
		<span class="var-title">
			<span class="var-type">int</span>
			<span class="var-name">$errno</span>
						(line <span class="line-number">91</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Fsockopen() error codes.</p>
	
	
		
		

</div>
<a name="var$errstr" id="$errstr"><!-- --></A>
<div class="oddrow">

	<div class="var-header">
		<span class="var-title">
			<span class="var-type">string</span>
			<span class="var-name">$errstr</span>
						(line <span class="line-number">96</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Fsockopen() error codes.</p>
	
	
		
		

</div>
<a name="var$handle" id="$handle"><!-- --></A>
<div class="evenrow">

	<div class="var-header">
		<span class="var-title">
			<span class="var-type">resource</span>
			<span class="var-name">$handle</span>
			 = <span class="var-default"> null</span>			(line <span class="line-number">56</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">A connection handle</p>
	
	
		
		

</div>
<a name="var$password" id="$password"><!-- --></A>
<div class="oddrow">

	<div class="var-header">
		<span class="var-title">
			<span class="var-type">string</span>
			<span class="var-name">$password</span>
			 = <span class="var-default"> false</span>			(line <span class="line-number">81</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">A password to authenticate with</p>
	
	
		
		

</div>
<a name="var$port" id="$port"><!-- --></A>
<div class="evenrow">

	<div class="var-header">
		<span class="var-title">
			<span class="var-type">int</span>
			<span class="var-name">$port</span>
			 = <span class="var-default"> null</span>			(line <span class="line-number">61</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">The remote port number</p>
	
	
		
		

</div>
<a name="var$PORT_DEFAULT" id="$PORT_DEFAULT"><!-- --></A>
<div class="oddrow">

	<div class="var-header">
		<span class="var-title">
			<span class="var-type">mixed</span>
			<span class="var-name">$PORT_DEFAULT</span>
			 = <span class="var-default"> SWIFT_SMTP_PORT_DEFAULT</span>			(line <span class="line-number">43</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Constant for the default SMTP port</p>
	
	
		
		

</div>
<a name="var$PORT_SECURE" id="$PORT_SECURE"><!-- --></A>
<div class="evenrow">

	<div class="var-header">
		<span class="var-title">
			<span class="var-type">mixed</span>
			<span class="var-name">$PORT_SECURE</span>
			 = <span class="var-default"> SWIFT_SMTP_PORT_SECURE</span>			(line <span class="line-number">47</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Constant for the default secure SMTP port</p>
	
	
		
		

</div>
<a name="var$timeout" id="$timeout"><!-- --></A>
<div class="oddrow">

	<div class="var-header">
		<span class="var-title">
			<span class="var-type">int</span>
			<span class="var-name">$timeout</span>
			 = <span class="var-default"> 15</span>			(line <span class="line-number">71</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">A connection timeout</p>
	
	
		
		

</div>
<a name="var$username" id="$username"><!-- --></A>
<div class="evenrow">

	<div class="var-header">
		<span class="var-title">
			<span class="var-type">string</span>
			<span class="var-name">$username</span>
			 = <span class="var-default"> false</span>			(line <span class="line-number">76</span>)
		</span>
	</div>

	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">A username to authenticate with</p>
	
	
		
		

</div>
							<h4>Inherited Variables</h4>
				<A NAME='inherited_vars'><!-- --></A>
									<p>Inherited from <span class="classname"><a href="../Swift_Connection/Swift_ConnectionBase.html">Swift_ConnectionBase</a></span></p>
					<blockquote>
													<span class="var-title">
								<span class="var-name"><a href="../Swift_Connection/Swift_ConnectionBase.html#var$extensions">Swift_ConnectionBase::$extensions</a></span><br>
							</span>
													<span class="var-title">
								<span class="var-name"><a href="../Swift_Connection/Swift_ConnectionBase.html#var$isESMTP">Swift_ConnectionBase::$isESMTP</a></span><br>
							</span>
											</blockquote> 
										
		</div>
	</div>
	
	<a name="sec-methods"></a>
	<div class="info-box">
		<div class="info-box-title">Methods</div>
		<div class="nav-bar">
			<a href="#sec-description">Description</a> |
															<a href="#sec-var-summary">Vars</a> (<a href="#sec-vars">details</a>)
																	<a href="#sec-method-summary">Methods</a> (<span class="disabled">details</span>)
						
		</div>
		<div class="info-box-body">
			<A NAME='method_detail'></A>

<a name="methodSwift_Connection_SMTP" id="Swift_Connection_SMTP"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">Constructor Swift_Connection_SMTP</span> (line <span class="line-number">104</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Constructor</p>
	
	<div class="method-signature">
		<span class="method-result">Swift_Connection_SMTP</span>
		<span class="method-name">
			Swift_Connection_SMTP
		</span>
					([<span class="var-type">string</span>&nbsp;<span class="var-name">$server</span> = <span class="var-default">&quot;localhost&quot;</span>], [<span class="var-type">int</span>&nbsp;<span class="var-name">$port</span> = <span class="var-default">null</span>], [<span class="var-type">int</span>&nbsp;<span class="var-name">$encryption</span> = <span class="var-default">null</span>])
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">string</span>
				<span class="var-name">$server</span><span class="var-description">: The remote server to connect to</span>			</li>
					<li>
				<span class="var-type">int</span>
				<span class="var-name">$port</span><span class="var-description">: The remote port to connect to</span>			</li>
					<li>
				<span class="var-type">int</span>
				<span class="var-name">$encryption</span><span class="var-description">: The encryption level to use</span>			</li>
				</ul>
		
			
	</div>
<a name="method__destruct" id="__destruct"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">Destructor __destruct</span> (line <span class="line-number">485</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Destructor.</p>
<p class="description"><p>Cleans up any open connections.</p></p>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			__destruct
		</span>
				()
			</div>
	
		
			
	</div>
<a name="methodattachAuthenticator" id="attachAuthenticator"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">attachAuthenticator</span> (line <span class="line-number">205</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Add an authentication mechanism to authenticate with</p>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			attachAuthenticator
		</span>
					(<span class="var-type"><a href="../Swift_Authenticator/Swift_Authenticator.html">Swift_Authenticator</a></span>&nbsp;<span class="var-name">&$auth</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type"><a href="../Swift_Authenticator/Swift_Authenticator.html">Swift_Authenticator</a></span>
				<span class="var-name">&$auth</span>			</li>
				</ul>
		
			
	</div>
<a name="methodgetEncryption" id="getEncryption"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">getEncryption</span> (line <span class="line-number">236</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Get the current encryption level used</p>
<p class="description"><p>This method returns an integer corresponding to one of the constants ENC_TLS, ENC_SSL or ENC_OFF</p></p>
	
	<div class="method-signature">
		<span class="method-result">int</span>
		<span class="method-name">
			getEncryption
		</span>
				()
			</div>
	
		
			
	</div>
<a name="methodgetPassword" id="getPassword"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">getPassword</span> (line <span class="line-number">197</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Get the password for authentication</p>
	
	<div class="method-signature">
		<span class="method-result">string</span>
		<span class="method-name">
			getPassword
		</span>
				()
			</div>
	
		
			
	</div>
<a name="methodgetPort" id="getPort"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">getPort</span> (line <span class="line-number">165</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Get the remote port number currently used to connect</p>
	
	<div class="method-signature">
		<span class="method-result">int</span>
		<span class="method-name">
			getPort
		</span>
				()
			</div>
	
		
			
	</div>
<a name="methodgetServer" id="getServer"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">getServer</span> (line <span class="line-number">144</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Get the remote server name</p>
	
	<div class="method-signature">
		<span class="method-result">string</span>
		<span class="method-name">
			getServer
		</span>
				()
			</div>
	
		
			
	</div>
<a name="methodgetTimeout" id="getTimeout"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">getTimeout</span> (line <span class="line-number">123</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Get the timeout currently set for connecting</p>
	
	<div class="method-signature">
		<span class="method-result">int</span>
		<span class="method-name">
			getTimeout
		</span>
				()
			</div>
	
		
			
	</div>
<a name="methodgetUsername" id="getUsername"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">getUsername</span> (line <span class="line-number">181</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Get the username for authentication</p>
	
	<div class="method-signature">
		<span class="method-result">string</span>
		<span class="method-name">
			getUsername
		</span>
				()
			</div>
	
		
			
	</div>
<a name="methodisAlive" id="isAlive"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">isAlive</span> (line <span class="line-number">477</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Check if the SMTP connection is alive</p>
	
	<div class="method-signature">
		<span class="method-result">boolean</span>
		<span class="method-name">
			isAlive
		</span>
				()
			</div>
	
		
			<hr class="separator" />
		<div class="notes">Redefinition of:</div>
		<dl>
			<dt><a href="../Swift_Connection/Swift_Connection.html#methodisAlive">Swift_Connection::isAlive()</a></dt>
						<dd>Check if the connection is up or not</dd>
					</dl>
			
	</div>
<a name="methodpostConnect" id="postConnect"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">postConnect</span> (line <span class="line-number">352</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Authenticate if required to do so</p>
	<ul class="tags">
				<li><span class="field">throws:</span> Swift_ConnectionException If authentication fails</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			postConnect
		</span>
					(<span class="var-type"><a href="../Swift/Swift.html">Swift</a></span>&nbsp;<span class="var-name">&$instance</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type"><a href="../Swift/Swift.html">Swift</a></span>
				<span class="var-name">&$instance</span><span class="var-description">: An instance of Swift</span>			</li>
				</ul>
		
			<hr class="separator" />
		<div class="notes">Redefinition of:</div>
		<dl>
			<dt><a href="../Swift_Connection/Swift_ConnectionBase.html#methodpostConnect">Swift_ConnectionBase::postConnect()</a></dt>
						<dd>Execute any needed logic after connecting and handshaking</dd>
					</dl>
			
	</div>
<a name="methodread" id="read"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">read</span> (line <span class="line-number">247</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Read a full response from the buffer</p>
<p class="description"><p>inner !feof() patch provided by Christian Rodriguez:  &lt;a href=&quot;http://www.flyspray.org/&quot;&gt;www.flyspray.org&lt;/a&gt;</p></p>
	<ul class="tags">
				<li><span class="field">throws:</span> Swift_ConnectionException Upon failure to read</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">string</span>
		<span class="method-name">
			read
		</span>
				()
			</div>
	
		
			<hr class="separator" />
		<div class="notes">Redefinition of:</div>
		<dl>
			<dt><a href="../Swift_Connection/Swift_Connection.html#methodread">Swift_Connection::read()</a></dt>
						<dd>Return the contents of the buffer</dd>
					</dl>
			
	</div>
<a name="methodrunAuthenticators" id="runAuthenticators"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">runAuthenticators</span> (line <span class="line-number">367</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Run each authenticator in turn an try for a successful login</p>
<p class="description"><p>If none works, throw an exception</p></p>
	<ul class="tags">
				<li><span class="field">throws:</span> Swift_ConnectionException Upon failure to authenticate</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			runAuthenticators
		</span>
					(<span class="var-type">string</span>&nbsp;<span class="var-name">$user</span>, <span class="var-type">string</span>&nbsp;<span class="var-name">$pass</span>, <span class="var-type"><a href="../Swift/Swift.html">Swift</a></span>&nbsp;<span class="var-name">&$swift</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">string</span>
				<span class="var-name">$user</span><span class="var-description">: Username</span>			</li>
					<li>
				<span class="var-type">string</span>
				<span class="var-name">$pass</span><span class="var-description">: Password</span>			</li>
					<li>
				<span class="var-type"><a href="../Swift/Swift.html">Swift</a></span>
				<span class="var-name">&$swift</span><span class="var-description">: An instance of swift</span>			</li>
				</ul>
		
			
	</div>
<a name="methodsetEncryption" id="setEncryption"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">setEncryption</span> (line <span class="line-number">226</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Set the encryption level to use on the connection</p>
<p class="description"><p>See the constants ENC_TLS, ENC_SSL and ENC_OFF  NOTE: PHP needs to have been compiled with OpenSSL for SSL and TLS to work  NOTE: Some PHP installations will not have the TLS stream wrapper</p></p>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			setEncryption
		</span>
					(<span class="var-type">int</span>&nbsp;<span class="var-name">$enc</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">int</span>
				<span class="var-name">$enc</span><span class="var-description">: Level of encryption</span>			</li>
				</ul>
		
			
	</div>
<a name="methodsetPassword" id="setPassword"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">setPassword</span> (line <span class="line-number">189</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Set the password for SMTP authentication</p>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			setPassword
		</span>
					(<span class="var-type">string</span>&nbsp;<span class="var-name">$pass</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">string</span>
				<span class="var-name">$pass</span><span class="var-description">: Password to use</span>			</li>
				</ul>
		
			
	</div>
<a name="methodsetPort" id="setPort"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">setPort</span> (line <span class="line-number">152</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Set the remote port number to connect to</p>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			setPort
		</span>
					(<span class="var-type">int</span>&nbsp;<span class="var-name">$port</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">int</span>
				<span class="var-name">$port</span><span class="var-description">: Port number</span>			</li>
				</ul>
		
			
	</div>
<a name="methodsetServer" id="setServer"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">setServer</span> (line <span class="line-number">131</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Set the remote server to connect to as a FQDN</p>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			setServer
		</span>
					(<span class="var-type">string</span>&nbsp;<span class="var-name">$server</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">string</span>
				<span class="var-name">$server</span><span class="var-description">: Server name</span>			</li>
				</ul>
		
			
	</div>
<a name="methodsetTimeout" id="setTimeout"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">setTimeout</span> (line <span class="line-number">115</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Set the timeout to connect in seconds</p>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			setTimeout
		</span>
					(<span class="var-type">int</span>&nbsp;<span class="var-name">$time</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">int</span>
				<span class="var-name">$time</span><span class="var-description">: Timeout to use</span>			</li>
				</ul>
		
			
	</div>
<a name="methodsetUsername" id="setUsername"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">setUsername</span> (line <span class="line-number">173</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Provide a username for authentication</p>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			setUsername
		</span>
					(<span class="var-type">string</span>&nbsp;<span class="var-name">$user</span>)
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">string</span>
				<span class="var-name">$user</span><span class="var-description">: The username</span>			</li>
				</ul>
		
			
	</div>
<a name="methodsmtpErrors" id="smtpErrors"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">smtpErrors</span> (line <span class="line-number">343</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Get the smtp error string as recorded by fsockopen()</p>
	
	<div class="method-signature">
		<span class="method-result">string</span>
		<span class="method-name">
			smtpErrors
		</span>
				()
			</div>
	
		
			
	</div>
<a name="methodstart" id="start"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">start</span> (line <span class="line-number">299</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Try to start the connection</p>
	<ul class="tags">
				<li><span class="field">throws:</span> Swift_ConnectionException Upon failure to start</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			start
		</span>
				()
			</div>
	
		
			<hr class="separator" />
		<div class="notes">Redefinition of:</div>
		<dl>
			<dt><a href="../Swift_Connection/Swift_Connection.html#methodstart">Swift_Connection::start()</a></dt>
						<dd>Try to start the connection</dd>
					</dl>
			
	</div>
<a name="methodstop" id="stop"><!-- --></a>
<div class="evenrow">
	
	<div class="method-header">
		<span class="method-title">stop</span> (line <span class="line-number">455</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Try to close the connection</p>
	<ul class="tags">
				<li><span class="field">throws:</span> Swift_ConnectionException Upon failure to close</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			stop
		</span>
				()
			</div>
	
		
			<hr class="separator" />
		<div class="notes">Redefinition of:</div>
		<dl>
			<dt><a href="../Swift_Connection/Swift_Connection.html#methodstop">Swift_Connection::stop()</a></dt>
						<dd>Try to stop the connection</dd>
					</dl>
			
	</div>
<a name="methodwrite" id="write"><!-- --></a>
<div class="oddrow">
	
	<div class="method-header">
		<span class="method-title">write</span> (line <span class="line-number">280</span>)
	</div> 
	
	<!-- ========== Info from phpDoc block ========= -->
<p class="short-description">Write a command to the server (leave off trailing CRLF)</p>
	<ul class="tags">
				<li><span class="field">throws:</span> Swift_ConnectionException Upon failure to write</li>
			</ul>
	
	<div class="method-signature">
		<span class="method-result">void</span>
		<span class="method-name">
			write
		</span>
					(<span class="var-type">string</span>&nbsp;<span class="var-name">$command</span>, [<span class="var-type"></span>&nbsp;<span class="var-name">$end</span> = <span class="var-default">&quot;\r\n&quot;</span>])
			</div>
	
			<ul class="parameters">
					<li>
				<span class="var-type">string</span>
				<span class="var-name">$command</span><span class="var-description">: The command to send</span>			</li>
					<li>
				<span class="var-type"></span>
				<span class="var-name">$end</span>			</li>
				</ul>
		
			<hr class="separator" />
		<div class="notes">Redefinition of:</div>
		<dl>
			<dt><a href="../Swift_Connection/Swift_Connection.html#methodwrite">Swift_Connection::write()</a></dt>
						<dd>Write a command to the buffer</dd>
					</dl>
			
	</div>
							<h4>Inherited Methods</h4>
				<a name='inherited_methods'><!-- --></a>	
									<!-- =========== Summary =========== -->
					<p>Inherited From <span class="classname"><a href="../Swift_Connection/Swift_ConnectionBase.html">Swift_ConnectionBase</a></span></p>
					<blockquote>
													<span class="method-name"><a href="../Swift_Connection/Swift_ConnectionBase.html#methodgetAttributes">Swift_ConnectionBase::getAttributes()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_ConnectionBase.html#methodgetRequiresEHLO">Swift_ConnectionBase::getRequiresEHLO()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_ConnectionBase.html#methodhasExtension">Swift_ConnectionBase::hasExtension()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_ConnectionBase.html#methodpostConnect">Swift_ConnectionBase::postConnect()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_ConnectionBase.html#methodsetExtension">Swift_ConnectionBase::setExtension()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_ConnectionBase.html#methodsetRequiresEHLO">Swift_ConnectionBase::setRequiresEHLO()</a></span><br>
											</blockquote>
									<!-- =========== Summary =========== -->
					<p>Inherited From <span class="classname"><a href="../Swift_Connection/Swift_Connection.html">Swift_Connection</a></span></p>
					<blockquote>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodgetAttributes">Swift_Connection::getAttributes()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodgetRequiresEHLO">Swift_Connection::getRequiresEHLO()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodhasExtension">Swift_Connection::hasExtension()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodisAlive">Swift_Connection::isAlive()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodpostConnect">Swift_Connection::postConnect()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodread">Swift_Connection::read()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodsetExtension">Swift_Connection::setExtension()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodsetRequiresEHLO">Swift_Connection::setRequiresEHLO()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodstart">Swift_Connection::start()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodstop">Swift_Connection::stop()</a></span><br>
													<span class="method-name"><a href="../Swift_Connection/Swift_Connection.html#methodwrite">Swift_Connection::write()</a></span><br>
											</blockquote>
										
		</div>
	</div>


	<p class="notes" id="credit">
		Documentation generated on Wed, 26 Mar 2008 20:33:51 +1100 by <a href="http://www.phpdoc.org" target="_blank">phpDocumentor 1.3.1</a>
	</p>
	</div></body>
</html>